<?php if (!defined('THINK_PATH')) exit(); /*a:4:{s:65:"/home/wwwroot/tp5/public/../application/blog/view/user/index.html";i:1489073627;s:61:"/home/wwwroot/tp5/public/../application/blog/view/layout.html";i:1488546775;s:36:"../application/blog/view/header.html";i:1488621955;s:36:"../application/blog/view/footer.html";i:1488546775;}*/ ?>
<!DOCTYPE html>
<html lang="zh-cn">
    <head>
        <meta charset="utf-8">
        <meta http-equiv="X-UA-Compatible" content="IE=edge">
        <meta name="viewport" content="width=device-width, initial-scale=1">
        <title><?php echo \think\Request::instance()->action(); ?></title>

        <!-- Bootstrap CSS -->
        <link href="//netdna.bootstrapcdn.com/bootstrap/3.2.0/css/bootstrap.min.css" rel="stylesheet">
        <style>
            html,body {
                height: 100%;
                }
            .container {
                /*background: #ccc; */
                width: 100%; 
                height: 100%
                }
            #header {
                background-color: royalblue;
                height: 10%
            }
            #middle {
                /*background: peru; */
                height: 86%
            }
            #footer {
                height: 4%; 
            }
            #left-side-menu {
                /*background: dodgerblue;*/
                height: 100%;
                padding: 0;
            }
        </style>

        <!-- HTML5 Shim and Respond.js IE8 support of HTML5 elements and media queries -->
        <!-- WARNING: Respond.js doesn't work if you view the page via file:// -->
        <!--[if lt IE 9]>
            <script src="https://oss.maxcdn.com/libs/html5shiv/3.7.0/html5shiv.js"></script>
            <script src="https://oss.maxcdn.com/libs/respond.js/1.4.2/respond.min.js"></script>
        <![endif]-->
        <!-- jQuery -->
        <script src="//code.jquery.com/jquery.js"></script>
        <!-- Bootstrap JavaScript -->
        <script src="//netdna.bootstrapcdn.com/bootstrap/3.2.0/js/bootstrap.min.js"></script>
    </head>
    <body>
 <div class="container">
	<div class="row">

		<div class="col-xs-2 col-sm-2 col-md-2 col-lg-2">

		</div>

		<div class="col-xs-8 col-sm-8 col-md-8 col-lg-8">
			<table class="table table-hover">
				<thead>
					<tr class='info'>
						<th>id</th>
						<th>name</th>
						<th>createtime</th>
						<th>updatetime</th>
						<th>action</th>
					</tr>
				</thead>
				<tbody>
					<?php if(is_array($users) || $users instanceof \think\Collection || $users instanceof \think\Paginator): $i = 0; $__LIST__ = $users;if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$user): $mod = ($i % 2 );++$i;?>
					<tr>
						<td><?php echo $user['id']; ?></td>
						<td><?php echo $user['username']; ?></td>
						<td><?php echo $user['create_time']; ?></td>
						<td><?php echo $user['update_time']; ?></td>
						<td><a href='#identifier' class="btn btn-primary btn-xs" data-toggle="modal">detail</a>/
							<a href='/blog/user/editor/id/<?php echo $user['id']; ?>' class="btn btn-warning btn-xs">editor</a>/
							<a href='/blog/user/delete/id/<?php echo $user['id']; ?>' class="btn btn-danger btn-xs">删除</a>
						</td>
					</tr>
					<?php endforeach; endif; else: echo "" ;endif; ?>
				</tbody>
			</table>
			<?php echo $page; ?>
		</div>

		<div class="col-xs-2 col-sm-2 col-md-2 col-lg-2">

		</div>
	</div>
</div>

<div class="modal fade" id="identifier" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
	<div class="modal-dialog">
		<div class="modal-content">
			<div class="modal-header">
				<button type="button" class="close" data-dismiss="modal" aria-hidden="true">
                  			&times;           
            			 </button>
				<h4 class="modal-title" id="myModalLabel">
					editor user
				</h4>
			</div>
			<div class="modal-body">
				<form action="" method="post" class="form-horizontal" role="form">
					<div class="form-group">
						<label for="username" class="col-sm-2 control-label">名字</label>
						<div class="col-sm-10">
							<input type="text" name="username" id="username" class="form-control" />
						</div>
					</div>
					<div class="form-group">
						<label for="password" class="col-sm-2 control-label">密码</label>
						<div class="col-sm-10">
							<input type="password" name="password" id="password" class="form-control" />
						</div>
					</div>
					<div class="form-group">
						<label for="confirm-password" class="col-sm-2 control-label">确认密码</label>
						<div class="col-sm-10">
							<input type="password" name="confirm-password" id="confirm-password" class="form-control" />
						</div>
					</div>
					<div class="form-group">
						<label for="email" class="col-sm-2 control-label">邮箱</label>
						<div class="col-sm-10">
							<input type="email" name="email" id="email" class="form-control" />
						</div>
					</div>
					<div class="form-group">
						<label for="phone" class="col-sm-2 control-label">手机</label>
						<div class="col-sm-10">
							<input type="text" name="phone" id="phone" class="form-control" />
						</div>
					</div>
				</form>
			</div>
			<div class="modal-footer">
				<button type="button" class="btn btn-default" data-dismiss="modal">
               关闭            
           </button>
				<button type="button" class="btn btn-primary">
               提交更改            
           </button>
			</div>
		</div>
		<!-- /.modal-content -->
	</div>
	<!-- /.modal -->


	<script>
		$(function () {
			$('form').submit(function (e) {
				//e.preventDefault();
				alert($('#username').val());
			});
		});
	</script>
    </body>
</html>